import request from '@/utils/request'

export const login = (data) => {
  return request({
    url: '/sys/login',
    method: 'POST',
    data
  })
}

// 获取用户资料
export const getUserInfo = () => {
  return request({
    url: '/sys/profile',
    method: 'POST'
  })
}

// 根据id获取用户详情
export const getUserDetailById = (id) => {
  return request({
    url: `/sys/user/${id}`,
    method: 'GET'
  })
}
